package com.datasecops.scannerservices.entity;

import com.datasecops.scannerservices.enumerate.DBType;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 公共传参Bean
 *
 * @author: SunLingzhi
 * @time: 2022/8/20 15:59
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class CommonParam {

    private String UUId;

    private String jobId;

    private String ip;

    private int port;

    private String userName;

    private String password;

    private DBType typeEnum;

    private String dbName;

    private String Instance;

    private String tableName;

    private String sql;

    private Integer maximumRows;
    private String model;

    private String PolicyPath;

    private String FingerPath;

    private String DictPath;

    private String MchClusterPath;

    public CommonParam(DBType typeEnum, String ip, int port, String userName, String password, String dbName, String instance) {
        this.typeEnum = typeEnum;
        this.ip = ip;
        this.port = port;
        this.userName = userName;
        this.password = password;
        this.dbName = dbName;
        this.Instance = instance;
    }

    public CommonParam(String uuId, String jobId, DBType typeEnum, String ip, int port, String userName, String password, String dbName, String tableName, String sql, Integer maximumRows,String instance) {
        this.UUId = uuId;
        this.jobId = jobId;
        this.typeEnum = typeEnum;
        this.ip = ip;
        this.port = port;
        this.userName = userName;
        this.password = password;
        this.sql = sql;
        this.dbName = dbName;
        this.tableName = tableName;
        this.maximumRows = maximumRows;
        this.Instance = instance;
    }

    public CommonParam(String uuId, String jobId, DBType typeEnum, String ip, int port, String userName, String password, String dbName, String tableName, String sql, Integer maximumRows,String instance,String model) {
        this.UUId = uuId;
        this.jobId = jobId;
        this.typeEnum = typeEnum;
        this.ip = ip;
        this.port = port;
        this.userName = userName;
        this.password = password;
        this.sql = sql;
        this.dbName = dbName;
        this.tableName = tableName;
        this.maximumRows = maximumRows;
        this.Instance = instance;
        this.model = model;
    }

    public CommonParam(String uuId, String jobId, DBType typeEnum, String endPoInt, String accessKeyId, String accessKeySecret, String buketName,String model) {
        this.UUId = uuId;
        this.jobId = jobId;
        this.typeEnum = typeEnum;
        this.ip = endPoInt;
        this.userName = accessKeyId;
        this.password = accessKeySecret;
        this.dbName = buketName;
        this.model = model;
    }
}
